import request from '@/utils/request'

// 查询违章条例配置列表
export function listRegulation(query) {
  return request({
    url: '/manger/regulation/list',
    method: 'get',
    params: query
  })
}

// 分页查询违章条例配置列表
export function pageRegulation(query) {
  return request({
    url: '/manger/regulation/page',
    method: 'get',
    params: query
  })
}
// 查询违章条例配置详细
export function getRegulation(id) {
  return request({
    url: '/manger/regulation/' + id,
    method: 'get'
  })
}

// 新增违章条例配置
export function addRegulation(data) {
  return request({
    url: '/manger/regulation',
    method: 'post',
    data: data
  })
}

// 修改违章条例配置
export function updateRegulation(data) {
  return request({
    url: '/manger/regulation',
    method: 'put',
    data: data
  })
}

// 删除违章条例配置
export function delRegulation(id) {
  return request({
    url: '/manger/regulation/' + id,
    method: 'delete'
  })
}
